package demo2;

/**
 * @Author liangzai
 * @Description:
 */
public class ShapeTest {
    public static void main(String[] args) {
        Rectangle rectangle = new Rectangle("红",3,8);
        Circle circle = new Circle("蓝",4.3);

        System.out.println("矩形的颜色："+rectangle.getColor());
        System.out.println("矩形的周长："+rectangle.getPerimeter());
        System.out.println("矩形的面积："+rectangle.getArea());

        System.out.println("---------------------------------");

        System.out.println("圆的颜色："+circle.getColor());
        System.out.println("圆的周长："+circle.getPerimeter());
        System.out.println("圆的面积："+circle.getArea());
    }
}
